#ifndef _RECOPROXY_VAD_H_
#define _RECOPROXY_VAD_H_

#ifdef __cplusplus
extern "C" {
#endif
enum VADTIMETYPE{
	VAD_TIME_UNKNOWN,
	VAD_TIME_START,
	VAD_TIME_END
};
typedef struct vadVars{
	int   _iDetect;
    int   _iIsBegin;
    int   _iIsEnd;
    int   _iHasVoice;
    int   _iIndex;
	int   _iPos;
	int   _iTime;
	int  _iFirstFrame;
}vadVars;
typedef void (*vadCallBackFunc) (void*, unsigned char* , int, vadVars* );
typedef void * CBINST ;
typedef void (*vadCloseCb) (void*);
typedef void (*vadCbUpdateTime) (void*,int, int);
typedef struct vadCbUtil {
	vadCallBackFunc _vadCbFunc;
	vadCloseCb      _vadCbCloseFunc;
	vadCbUpdateTime _vadCbUpdateTimeFunc;
	CBINST          _vadCbInst;
}vadCbUtil;
vadCbUtil* createVadCbUtil(vadCallBackFunc vadCbFunc, vadCloseCb vadCbCloseFunc, vadCbUpdateTime vadCbUpdateTimeFunc, CBINST vadCbInst);
void releaseVadCbUtil(vadCbUtil* pUtil);
void* recoProxyCreateVad(void* pVadOptions, int iType,vadCbUtil* pCbUtil);
void recoProxyInitVad(void* pVadHdl);
void recoProxyVadFeedData(void* pVadHdl,char* pData,int iLen);
void recoProxyCloseVad(void* pVadHdl);

#ifdef __cplusplus
}
#endif

#endif
